package org.JQbitorrentClinet;

import lombok.Builder;
import lombok.Getter;
import org.JQbitorrentClinet.base.BaseParam;
import org.JQbitorrentClinet.utils.InternalHttpClient;

@Builder
@Getter
public class QBitorrentConnectionInfo {
    String host;
    int port;
    String username;
    String password;
    String protocol = "http";
    InternalHttpClient internalHttpClient;

    public String getUrl() {
        return protocol+ "://" + host + ":" + port;
    }

    public String getUrl(BaseParam param) {
        return getUrl() + param.getApiUrl();
    }
}
